home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Interactive Web Graphics with Shout 3D
/
Interactive Web Graphics With Shout 3D.iso
/
mac
/
Shout3Ddemo
/
Shout3d_runtime
/
codebase
/
models
/
viewpointTest.s3d
< prev
next >
Wrap
Text File
|
2000-05-30
|
6KB
|
186 lines
#VRML V2.0 utf8
Transform {
translation 0 4 0
rotation 1 0 0 0.4
children [
DEF CUBE2 Transform {
translation 0 2 0
children [
Shape {
appearance Appearance {
material Material {diffuseColor 1 0 0 emissiveColor 0 0 0.5}
}
geometry IndexedFaceSet {
coord Coordinate {
point [
-1 -1 1
-1 1 1
1 1 1
1 -1 1
-1 -1 -1
-1 1 -1
1 1 -1
1 -1 -1
]
}
texCoord TextureCoordinate {
point [
0 0
1 0
1 1
0 1
]
}
coordIndex [
0 3 1 -1
3 2 1 -1
3 7 2 -1
7 6 2 -1
7 4 6 -1
4 5 6 -1
4 0 5 -1
0 1 5 -1
1 2 5 -1
2 6 5 -1
0 4 3 -1
4 7 3 -1
]
texCoordIndex [
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
]
}
}
]
}
DEF MyTrans Transform {
translation 0 0 0
rotation 0 1 0 0.9
children [
Transform {
translation 0 1 0
rotation 1 0 0 -0.4
children [
DEF Camera Viewpoint{
fieldOfView 0.785398
position 0 0 10
}
]
}
DEF CUBE1 Transform {
translation 0 -1 0
rotation 0 1 0 -0.6
children [
Shape {
appearance Appearance {
material Material {diffuseColor 1 0 0 emissiveColor 0 0.5 0}
}
geometry IndexedFaceSet {
coord Coordinate {
point [
-1 -1 1
-1 1 1
1 1 1
1 -1 1
-1 -1 -1
-1 1 -1
1 1 -1
1 -1 -1
]
}
texCoord TextureCoordinate {
point [
0 0
1 0
1 1
0 1
]
}
coordIndex [
0 3 1 -1
3 2 1 -1
3 7 2 -1
7 6 2 -1
7 4 6 -1
4 5 6 -1
4 0 5 -1
0 1 5 -1
1 2 5 -1
2 6 5 -1
0 4 3 -1
4 7 3 -1
]
texCoordIndex [
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
0 1 3 -1
1 2 3 -1
]
}
}
]
}
]
}
]
}
DEF TIMER TimeSensor{
cycleInterval 5.333
loop TRUE
}
DEF MYINTERP OrientationInterpolator{
key[
0 0.33 0.66 1
]
keyValue[
0 1 0 0
0 1 0 2.094
0 1 0 4.189
0 1 0 0
]
}
DEF MYINTERP2 PositionInterpolator{
key[
0 0.25 0.5 0.75 1
]
keyValue[
-1 0 -1
1 0 -1
1 0 1
-1 0 1
-1 0 -1
]
}
ROUTE TIMER.fraction_changed TO MYINTERP.set_fraction
ROUTE MYINTERP.value_changed TO MyTrans.set_rotation
ROUTE TIMER.fraction_changed TO MYINTERP2.set_fraction
ROUTE MYINTERP2.value_changed TO MyTrans.set_translation